import Layout from '@/layout'

const Router = {
  path: '/officialWebsite',
  component: Layout,
  redirect: '/banner-manage',
  name: 'officialWebsite',

  meta: {
    title: '官网配置',
    icon: 'officialWebsite'
  },
  children: [
    {
      path: 'banner-manage',
      component: () => import('@/views/officialWebsite/bannerManage/bannerManage'),
      name: 'bannerManage',
      meta: { title: '轮播图管理', noCache: true }
    },
    {
        path: '/article',
        component: Layout,
        name: 'article',
        meta: { title: '文章管理', noCache: true },
        children: [
            {
              path: 'article-list',
              component: () => import('@/views/officialWebsite/article/articleList'),
              name: 'articleList',
              meta: { title: '文章列表', noCache: true }
            },
            {
                path: 'article-sort',
                component: () => import('@/views/officialWebsite/article/articleSort'),
                name: 'articleSort',
                meta: { title: '文章分类', noCache: true }
            },
        ]
    },
    {
        path: '/video',
        component: Layout,
        name: 'video',
        meta: { title: '视频管理', noCache: true },
        children: [
            {
              path: 'video-list',
              component: () => import('@/views/officialWebsite/video/videoList'),
              name: 'videoList',
              meta: { title: '视频列表', noCache: true }
            },
            {
                path: 'video-sort',
                component: () => import('@/views/officialWebsite/video/videoSort'),
                name: 'videoSort',
                meta: { title: '视频分类', noCache: true }
            },
        ]
    },
    {
        path: 'contact-message',
        component: () => import('@/views/officialWebsite/contactMessage/contactMessage'),
        name: 'contactMessage',
        meta: { title: '联系留言', noCache: true }
    },
  ]
}

export default Router
